<template>
	<view class="title">
		<view>
			<image src="../../static/img/computer_icon.png" mode=""></image>
			<text>{{title}}</text>
		</view>
		<text @click="linkto(subtitleUrl)"  style="margin-right: 10rpx; color: #AAAAAA;">{{subtitle}}</text>
	</view>
</template>

<script>
	export default {
		name:"index-list-title",
		props:{
			subtitleUrl:{
				type:String,
				default:'',
			},
			title:{
				type:String,
				default:'标题'
			},
			subtitle:{
				type:String,
				default:'副标题'
			},
		},
		data() {
			return {
			};
			
		},
		mounted() {
			
		},
		methods:{
			linkto(url){
				uni.switchTab({
					url:url
				})
				
			}
		}
	}
</script>

<style lang="scss">
	.title{
		box-shadow: 0px 0px 3px #AAAAAA;
		display: flex;
		align-items: center;
		justify-content: space-between;
		margin: 10rpx 0;
		text{
			color: #333333
		}
		image{
			vertical-align: middle;
			padding: 15rpx 20rpx;
			width: 100rpx;
			height: 70rpx;
		}
		
	}
</style>
